home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 20 / Cream of the Crop 20 (Terry Blount) (1996).iso / os2 / fdupe009.zip / finddupe.txt < prev   
Text File  |  1996-06-30  |  8KB  |  237 lines

  1. ==============================================================================
  2.                             Find Dupe v0.09ß
  3. ==============================================================================
  4.  
  5. Ever want to find duplicate files on your system?  Get tired of setting up
  6. long, complicated configurations just to do that?  What about those
  7. duplicates you *know* about, and don't want to be bothered with?
  8.  
  9. Here is a simple program that won't solve everything, but does fix the above.
  10. FindDupe scans your harddrive(s) and lists *every* file you have, in
  11. alphabetical order based on filename rather than path.  And it will ignore
  12. files that you tell it, even based on wildcards!  If you don't want to see
  13. files ending in .bak, just tell the program to skip *.bak!
  14.  
  15. Program requirements:
  16. =====================
  17.  
  18. 386 or better
  19. OS/2 2.x or better (only tested on Warp Connect, FP 17)
  20. 8MB RAM recommended (more if you have more files to scan, otherwise the
  21.     swapping could become prohibitive.  This can be a memory-hungry
  22.         program!)
  23. HPFS recommended (extensive disk scanning is faster under HPFS than FAT).
  24.  
  25. Program use:
  26. ============
  27.  
  28.     finddupe [-c ConfigurationFile] [-o OutputFile] [-d <on|off>]
  29.  
  30. where:
  31.     -c ConfigurationFile tells the program where to find its
  32.             config file.  This defaults to FINDDUPE.CFG in the
  33.                 current directory.
  34.  
  35.     -o OutputFile tells the program where to place its output.
  36.             This may also be placed in the configuration file.
  37.                 The one on the commandline takes precedence, however.
  38.                 If there is no output file specified, the output is to
  39.                 stdout (i.e., redirect via >)
  40.  
  41.     -d tells the program whether the Dupes-Only mode should be used.
  42.             If it is on, FindDupe will not print files that are not
  43.                 duplicates.  Overrides the keyword in the configuration
  44.                 file.
  45.  
  46.  
  47. Note: User notification (current directory, action, etc.) is done to stderr.
  48. To hide all output, ensure you have an output file and redirect stderr as
  49. well (using '>2 nul')
  50.  
  51. Configuration File:
  52. ===================
  53.  
  54. This is a plain ASCII text file that has the following commands.
  55.  
  56.     skip <filespec>
  57.             Tells FindDupe to skip any file (or subdirectory) with
  58.                 this name.  For example, skip *.bak will skip all files
  59.                 ending in .bak
  60.  
  61.         setrecurse <on|off>
  62.             Tells FindDupe that from this point in the configuration
  63.                 file, all directories should be recursed (on) or not
  64.                 recursed (off) into their subdirectories unless the 
  65.                 subdirectory name is supposed to be skipped.
  66.                 Note: multiple of these may be used and only apply to
  67.                 directories named after the command.  Default for any
  68.                 directories before a setrecurse command is 'off'.
  69.  
  70.         recursive
  71.             Synonym for setrecurse on.
  72.  
  73.     nonrecursive
  74.             Synonym for setrecurse off.
  75.  
  76.     directory <directory to scan> [r|n]
  77.             Tells FindDupe which directories to look for.  Full pathname
  78.                 is required.  An optional 'r' or 'n' will override the
  79.                 default set by setrecurse: 'r' will turn on recurse for this
  80.                 directory, 'n' will turn it off.  Note that specifying a
  81.                 directory twice, either directly or due to recursion, will
  82.                 result in all files in that directory being counted twice.
  83.                 Perhaps later I will sort that out.
  84.  
  85.     usemaximus
  86.             Read in the Maximus 3.0x FAREA.DAT file and use all download
  87.                 paths.  Any areas read from the FAREA.DAT will *not* be
  88.                 recursed, regardless of the current default.
  89.                 In order to use this, your MAXIMUS environment variable
  90.                 *must* be set properly in the session running FindDupe.
  91.  
  92.         outfile <filename>
  93.             Set the output file.  Overridden by the commandline.
  94.  
  95.         dupesonly
  96.             Do not print out files that are not dupes.  Useful for only
  97.                 finding dupes without the lengthy listing of all files.
  98.  
  99.     ; <comment>
  100.         # <comment>
  101.             This may be put anywhere on a line.  Anything after a
  102.                 semicolon or pound character will be ignored.
  103.  
  104. Deciphering the output:
  105. =======================
  106.  
  107. The output looks like:
  108.  
  109. nn. (dd) YYYY/MM/DD size full\path\filename.ext
  110.  
  111. where nn is the number of unique filenames to this point (all duplicates
  112. will have the same 'nn') and dd is the number of the dupe that this is.
  113. For example:
  114.  
  115. ...
  116.  44. (1) 1992/03/29 124K c:\pacman\pacman.exe
  117.  45. (1) 1993/02/14  42K c:\zip\pkzip.exe 
  118.  45. (2) 1995/03/11  42K c:\backup\pkzip.exe 
  119.  46. (1) 1996/02/10  10K c:\bbs\file\fernwood\graphx\pointers.zip
  120.  47. (1) 1996/02/02  72K c:\bbs\file\fernwood\apps\polycalc.zip
  121. ...
  122.  
  123. As we notice, we have two copies of pkzip on the system in the directories
  124. specified.  They are both given unique file number 45, however one is found
  125. in the c:\zip directory and the other in the c:\backup directory.  The reason
  126. for giving them different dupe numbers is that this way you can do a text
  127. search for (2) to find all exact duplicate names.  If all dupes were given
  128. the same dupe number, we could have 3 files with the same name, meaning you
  129. would have to search for (2), (3), (4), etc.
  130.  
  131. The last file shown will be the number of unique filenames.  The final total
  132. of filenames will be placed at the bottom:
  133.  
  134. ...
  135. 447. (1) 1996/04/28 590K c:\bbs\file\fernwood\apps\zoc214.zip
  136.  
  137. Total: 487 files
  138.  
  139. In this case, we notice that there are 40 duplicates (487 - 447).
  140.  
  141.  
  142. Registering FindDupe:
  143. =====================
  144.  
  145. HAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHAHA!
  146.  
  147. (It's freeware)
  148.  
  149. Getting Support:
  150. ================
  151.  
  152. I can be reached at:
  153.  
  154. mcbride@ee.ualberta.ca
  155.  
  156. Or, via netmail to:
  157.  
  158. Fidonet: 1:342/708
  159. IBMNet: 40:6494/2004
  160. FireNet: 77:1403/1
  161.  
  162. Future possibilities:
  163. =====================
  164.  
  165. In my ever expanding need to learn the STL, I will try to add:
  166.    1. dupe matching against version numbers in the filename so that
  167.       'zoc210.zip' will match 'zoc213.zip'.
  168.    2. Smart overlap checking (i.e., detecting that we've done this directory
  169.       before)
  170.    3. BinkleyTerm support (via the F'REQ areas)
  171.    4. LoraBBS support
  172.  
  173. Source Code:
  174. ============
  175.  
  176. Perhaps, if you're really nice, I'll let you at it.  It's gotten ugly again...
  177.  
  178. This was compiled using the support of:
  179.  
  180. Watcom 10.6
  181. Hewlett-Packard's Standard Template Library
  182.  
  183.  
  184.  
  185. History:
  186. ========
  187.  
  188. Legend: * Rewrite of part or all
  189.         + Added
  190.         - Removed
  191.         ! Bugfix
  192.         . Notes
  193.  
  194.    0.09 + Added version comparisons.  ZOC210.ZIP compares as a dupe to
  195.           Zoc213.LHA and zOc2145.Zip.  The side effect is that it also
  196.           compares as a dupe to Zoc.extra.extentions.
  197.  
  198.    0.08
  199.        * Re-ordered some source to make it easier for me to follow.  Much
  200.           cleaned up
  201.         ! Minor changes to output format (i.e., 6.0M should be 6M)
  202.  
  203.    0.07
  204.        ! Recursing subdirectories didn't work.  Dumdumdum.  Fixed.
  205.  
  206.    0.06
  207.        + Added DupesOnly keyword
  208.     ! Clarified configuration file on new features since 0.04
  209.           (Yes, I consider documentation errors or usability as 'bugs')
  210.     + Added time display at conclusion of listing to show how long
  211.           scanning the drive took.
  212.         * Fixed history listings to be newest first (duh...)
  213.  
  214.    0.05
  215.        + Added date/size stamping
  216.  
  217.    0.04
  218.        * Got a book on STL.  :-)  Rewrote *everything* using STL instead.
  219.         + Added Maximus support
  220.         - Removed limitation on number of files to read at a time
  221.           (thanks, STL!)
  222.         . Done in 24 hours.
  223.         + Created readme/history
  224.  
  225.    0.03
  226.        * Got Watcom.  :-}
  227.         . Got the STL and started using it for part of this.  This messed me
  228.           up completely.
  229.         . Never finished.
  230.  
  231.    0.02
  232.        + Hacked in config-file support
  233.         . Only a couple people looked at it
  234.  
  235.    0.01
  236.        * Complete